package cm.tl.pms.enums.base;

import lombok.AccessLevel;
import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * "新建设项目
 * 新增购买服务
 * 升级改造项目
 * 延续性购买服务
 * 运维项目"
 */
@Getter
@AllArgsConstructor(access= AccessLevel.PRIVATE)
public enum ProjectEnum implements IEnum {
    NEW_CREATE("新建设项目", 1),
    NEW_ADD_SERVICE("新增购买服务", 2),
    UPGRADE("升级改造项目", 3),
    CONTINUE_SERVICE("延续性购买服务", 4),
    operations_project("运维项目", 5);
    private final String name;
    private final Integer value;

    public static ProjectEnum nameOf(Integer value) {
        for (ProjectEnum e : ProjectEnum.values()) {
            if (e.value.equals(value)) {
                return e;
            }
        }
        return null;
    }

}
